// 362 Project 1.cpp : Defines the entry point for the console application.
//

#include "stdafx.h"
#include <stdio.h>

void main()
{
	
	FILE *ifp, *ofp;
	int c, c1, c2, c3, c4, c5, c6;
	int n = 0;
	int count = 0;
	ifp = fopen("prog1in1.txt", "r");
	if(ifp == NULL){	
			
	}
	ofp = fopen("prog1in1out.txt", "w");
	
	do{
		c = getc(ifp);
		count++;
		if(c == '>'){
        fseek(ifp, count - 6, SEEK_SET);
        c1 = getc(ifp);
        c2 = getc(ifp);
        c3 = getc(ifp);
        c4 = getc(ifp);
        c5 = getc(ifp);

        if(c1 == '<' && c2 == 'b' && c3 == 'r' && c4 == ' ' && c5 == '\\' ){
			putc( '\n' , ofp);
		} 
	
	}

		fseek(ifp, count, SEEK_SET);
	
		
			putc(c, ofp);
	}while(c !=EOF);

	//for(c = getc(ifp); c!= EOF;)

	fclose(ifp);

	
	
	
	



	
}

